package com.westa.smallshop.data;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Created by Dune on 16/10/27.
 */

public class PageData implements Parcelable {


    private int count;
    private int limit;
    private int page;
    private String results;

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public int getLimit() {
        return limit;
    }

    public void setLimit(int limit) {
        this.limit = limit;
    }

    public int getPage() {
        return page;
    }

    public String getResults() {
        return results;
    }

    public void setResults(String results) {
        this.results = results;
    }

    public void setPage(int page) {
        this.page = page;
    }


    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.count);
        dest.writeInt(this.limit);
        dest.writeInt(this.page);
        dest.writeString(this.results);
    }

    public PageData() {
    }

    protected PageData(Parcel in) {
        this.count = in.readInt();
        this.limit = in.readInt();
        this.page = in.readInt();
        this.results = in.readString();
    }

    public static final Creator<PageData> CREATOR = new Creator<PageData>() {
        @Override
        public PageData createFromParcel(Parcel source) {
            return new PageData(source);
        }

        @Override
        public PageData[] newArray(int size) {
            return new PageData[size];
        }
    };
}
